package com.shenmazong.controller;

import com.shenmazong.dto.TbSoftware;
import com.shenmazong.service.TbSoftwareService;
import com.shenmazong.utils.ResultResponse;
import com.shenmazong.vo.BatchChooseIdVo;
import com.shenmazong.vo.ListParamVo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

/**
 * @author 阿瑞
 * @version 1.0
 * @description TODO
 * @class TbSoftwareController ???
 * @date 2021/9/21 18:37
 */
@RestController
@RequestMapping("software")
public class TbSoftwareController {
    @Autowired
    private TbSoftwareService tbSoftwareService;
    @PostMapping("findAllSoftwareAdmin")
    public ResultResponse findAllSoftwareAdmin(@RequestBody ListParamVo listParamVo){
        return tbSoftwareService.findAllSoftwareAdmin(listParamVo);
    }
    @PostMapping("softwareCache")
    public ResultResponse softwareCache(@RequestBody ListParamVo listParamVo){
        return tbSoftwareService.softwareCache(listParamVo);
    }
    @PostMapping("saveSoftware")
    public ResultResponse saveSoftware(@RequestBody TbSoftware tbSoftware){
        return tbSoftwareService.saveSoftware(tbSoftware);
    }
    @PostMapping("updateSoftware")
    public ResultResponse updateSoftware(@RequestBody TbSoftware tbSoftware){
        return tbSoftwareService.updateSoftware(tbSoftware);
    }
    @PostMapping("deleteSoftware")
    public ResultResponse deleteSoftware(@RequestBody BatchChooseIdVo batchChooseIdVo){
        return tbSoftwareService.deleteSoftware(batchChooseIdVo);
    }
    @PostMapping("auditSoftware")
    public ResultResponse auditSoftware(@RequestBody BatchChooseIdVo batchChooseIdVo){
        return tbSoftwareService.auditSoftware(batchChooseIdVo);
    }
}
